<?php

require_once PATH_CLASS.'widget.class.php';
require_once PATH_CLASS.'theme.class.php';
require_once PATH_CLASS.'membre.class.php';
require_once PATH_CLASS.'commun.class.php';

//theme::playTheme('blue');
//theme::playTheme('orange');
//theme::playTheme('rose');
//theme::playTheme('vert');

require ("./lib/smarty/plugins/function.score.php");


$smarty = commun::getSmarty();
$match = match::getMatch(329);

echo "*";
echo smarty_function_score(array('match_id'=>$match->match_id,'scoreA'=>$match->match_score_A,'scoreB'=>$match->match_score_B), $smarty);
echo "*";

echo membre::getLink(1,'',array('addImg'=>true))."<br />";
echo membre::getLink(2,'',array('addImg'=>true))."<br />";
echo membre::getLink(210,'',array('addImg'=>true))."<br />";
echo equipe::getLink(1,'',array('addImg'=>true))."<br />";

echo widget::render('form',array('type'=>'manageNews'));

echo tpl::getSelectFonctionsType('',0);

//echo membre::getLink(1,'',array('addImg'=>true))."<br />";
//echo membre::getLink(2,'',array('addImg'=>true))."<br />";

//for($i=1;$i<10;$i++){
//  echo equipe::getLink($i).'<br/>';
//  echo membre::getLink($i).'<br/>';
//}

?>

<?php

     

/* * /
     echo time();
     $db = commun::getDb();
     foreach(match::getMatchsBySaison(21) as $match){
       //var_dump($match->match_id);
       echo "{$match->match_id} av=".$match->match_has_image;
       $match->match_has_image = $match->getRealImagesCount();
       echo " ap=".$match->match_has_image."<br />";
       if($match->match_has_image>0){
        $match->updateHasImage($match->match_has_image); 
       }
       
     }
/* */     

/* * /
// Suppression des vignettes
	$chemin = '../www/datas/images/matchs/saison_21/';
	
	$matchs = scandir($chemin);
	
	foreach($matchs as $match){
		echo "*$match<br >";
		if($match!='..' && $match!='.'){
			$photos = scandir($chemin.$match);
			foreach($photos as $photo){
				if($photo!='..' && $photo!='.'){ 
					
					if($photo[0]='V'){
						$file = $chemin.$match.'/'.$photo;
						//@chmod($file, 0666);
						echo "****$file (".@unlink($file).")<br />";
						
					}
				}
			}
		}
	}

/* */

?>
